package f.admin.bo.entity;

import java.lang.reflect.Field;

import net.sf.json.JSONObject;


public abstract class BaseBusinessObject {

	public String getJsonString() {
		JSONObject jsonObj = new JSONObject();
		Field[] fields = this.getClass().getFields();
		for(int i = 0; i < fields.length; i++) {
			Field field = fields[i];
			try {
				jsonObj.put(field.getName(), field.get(this));
			} catch (Exception e) {
				e.printStackTrace();
			}
		}
		return jsonObj.toString();
	}
}
